package com.itheima.demo5;

import java.io.*;
import java.nio.charset.Charset;

public class IODemo11 {
    public static void main(String[] args) throws IOException {
//        OutputStreamWriter gbk = new OutputStreamWriter(new FileOutputStream("a.txt"), "GBK");
        FileWriter gbk = new FileWriter("a.txt", Charset.forName("GBK"));
        gbk.write("你好你好");
        gbk.close();



    }
}
